package cn.wolfcode.car.business.mapper;

import cn.wolfcode.car.business.domain.BusinessStatement;
import cn.wolfcode.car.business.query.BusinessStatementQuery;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

public interface BusinessStatementMapper {
    int deleteByPrimaryKey(Long id);

    int insert(BusinessStatement businessStatement);

    BusinessStatement selectByPrimaryKey(Long id);

    List<BusinessStatement> selectAll();

    int updateByPrimaryKey(BusinessStatement businessStatement);

    List<BusinessStatement> selectForList(BusinessStatementQuery qo);

    void updateStatement(@Param("statementId") Long statementId,
                         @Param("totalAmount") BigDecimal totalAmount,
                         @Param("totalQuantity") BigDecimal totalQuantity,
                         @Param("discountPrice") BigDecimal discountPrice,
                         @Param("paytime") Date paytime,
                         @Param("payeeId") Long payeeId);

    void updateStatus(@Param("statementId") Long id, @Param("statusPaid") Integer statusPaid);
}